home *** CD-ROM | disk | FTP | other *** search
/ BBS Toolkit / BBS Toolkit.iso / doors_1 / gut_200_.zip / DOORJAM.ZIP / DOORJAM.DOC < prev    next >
Text File  |  1991-01-22  |  5KB  |  151 lines

  1. DOORJAM Version 1.1 for PCBoard 14.x
  2.  
  3.    DOORJAM is a door lock for all door programs launched by .BAT files.
  4. It prevents 2 nodes from opening the same door at the same time.  If a
  5. node attempts to open a locked door, an ERRORLEVEL of 1 will be returned.
  6.  
  7.    DOORJAM goes one step further, if the system goes down while a door
  8. is being played, DOORJAM will remove the lock during the next OPEN of
  9. that door!!!
  10.  
  11. The system uses the following files:
  12.  
  13.     DOORJAM.DOC  This Documentation
  14.     DOORJAM.EXE  The main program
  15.     DOORJAM.CNF  Node Path list (up to 9 nodes)
  16.     DOORJAM.LOK  The Lock (Created by the main program)
  17.    ECHOBACK.EXE  Sends a file to the user's screen
  18.      LOCKED.CNF  Sample ECHOBACK Configuration file
  19.      LOCKED.     Sample ASCII screen
  20.     LOCKEDG.     Sample ANSI screen
  21.  
  22. -------------------------------------------------------------------
  23. How to code the DOORJAM.CNF file:
  24.  
  25.   1) Edit the file with an ASCII editor.
  26.   2) Each line represents a node path where the PCBOARD.SYS file for
  27.      that node can be found.
  28.   3) Line 1 = Node 1 etc.
  29.   4) Be sure to end each line with a backslash (\).
  30.   5) File the DOORJAM.CNF in the same directory as the .EXE.
  31.   6) Place a copy of the CNF file in each directory that contains
  32.      a DOOR batch file. (usually one per node)
  33.  
  34. A typical DOORJAM.CNF might look like this:
  35.  
  36. c:\PCB\
  37. d:\PCB2\
  38. c:\TEST\PCB3\
  39.  
  40.   In the above example, line 1 states that NODE 1 is at c:\PCB\, NODE 2
  41. is at d:\PCB2\ and NODE 3 at c:\TEST\PCB3\.  DOORJAM will currently use
  42. up to nine(9) nodes for locking.
  43. -------------------------------------------------------------------
  44. How to code the ECHOBACK.CNF file:
  45.  
  46.   1) Edit the file with an ASCII editor.
  47.   2) The Filename can be anything you like. (I recommend you make it
  48.      something relevant).
  49.   3) Line 1 MUST be INTERRUPT (Standard PROKIT command).
  50.   4) Line 2 is the path/filename of the screen to display. If you
  51.      want ANSI graphics to display (assuming the user can handle them)
  52.      just don't use a filename extention for the graphic file and make
  53.      sure the last letter of the filename is 'G'. In the supplied files
  54.      are 2 files call 'LOCKED' and 'LOCKEDG'.  The are the ASCII/ANSI
  55.      display screens.  Use these files like bulletins and menus!
  56.  
  57. An example of a useable .CNF is:
  58.  
  59. * * * Top of File * * *
  60. INTERRUPT
  61. C:\PCB\SCREENS\LOCKED
  62. * * * End of File * * *
  63.  
  64.   This file an be called anything so how about 'LOCKED.CNF'.  To call
  65. the screen code the BAT file like this:
  66.  
  67.                   ECHOBACK C:\DOORS\LOCKED.CNF C:\PCB
  68.  
  69. Where:
  70.   C:\DOORS\LOCKED.CNF  is the Path/filename for the ECHOBACK Config file.
  71.   C:\PCB   is where this node's PCBOARD.SYS is.
  72. ------------------------------------------------------------------
  73.  
  74. Syntax for DOORJAM:
  75.  
  76.   Doorjam cmd x:\ y:\
  77.  
  78.   Where: cmd = LOCK or UNLOCK
  79.          x:\ = Path where door program will be (and the lock).
  80.          y:\ = Path where current PCBoard.SYS file is.
  81.  
  82.    Let's say you want to DOORJAM your TRIVIA door.  Your TRIVIA door is
  83. located on drive 'D:' in directory '\door\triv'.  The user is on a node
  84. that puts PCBOARD.SYS in directory 'c:\PCB'.  To lock the door use:
  85. "DOORJAM LOCK D:\DOOR\TRIV C:\PCB".  To unlock the door when the user
  86. is done with it code: "DOORJAM UNLOCK D:\DOOR\TRIV".
  87.  
  88. Coding a .BAT file.
  89.  
  90. echo off
  91. DOORJAM LOCK c:\guppy c:\pcb       (Lock the door in c:\guppy)
  92. if errorlevel 1 Goto :skipit       (ERRORLEVEL 1 means door WAS locked)
  93. ...
  94. ...     execute the door here
  95. ...
  96. DOORJAM UNLOCK c:\                 (Make sure to UNLOCK it after play)
  97. ... Reload the board now
  98.  
  99. :skipit
  100. ECHOBACK C:\DOORS\LOCKED.CNF C:\PCB
  101. ... Reload the board now
  102. exit
  103.  
  104.  
  105.    REMEMBER: If ERRORLEVEL 1 then the door is locked by another node.
  106. DO NOT execute the door!  DO NOT UNLOCK this door from another node.
  107. If for some reason the node that issued a lock crashes before the UNLOCK
  108. command is issued do not worry.  The next time the door is requested,
  109. DOORJAM checks the LOK file and the node that issued it.  If the node
  110. and user don't match then the old LOK is removed and a new LOK issued.
  111.  
  112. ========================================================================
  113.  
  114. Registration :
  115.  
  116. Price of DOORJAM: $5.00
  117.  
  118. Send Cash, Check or Gold to: PAUL MCGINNESS
  119.  
  120.    C/O
  121.    ACC BBS
  122.    138 Fifth Ave, Suite 180
  123.    Pelham, NY, 10803
  124.  
  125. ATT: Paul McGinness
  126.  
  127. Contact me thru Relay-Net (COMMON).
  128. ========================================================================
  129.  
  130.  
  131. Why Register DOORJAM when it works fine now?
  132.  
  133.    Well, if you are one of those SYSOPs who never registers anything
  134. then you won't bother with this either I'm sure.  However, for the
  135. majority of honest SYSOPs who find this program of value to them, there
  136. is no reason other than I am saving up for an HST modem.  While I am not
  137. a SYSOP, I am an addicted DOOR player and QMAIL junkie.
  138.  
  139.    The latest release of DOORJAM will always be available on the
  140. following quailty BBS systems:
  141.  
  142.   ACC BBS          : 914-636-1455 : Skip Ross, SYSOP
  143.   The BRENTWOOD BBS: 914-835-7898 : Guy Cappello, SYSOP
  144.  
  145.  
  146.    I can also be reached through the RELAY-Net mail System (Use the
  147. COMMON conference).
  148.  
  149.   ....Thanks
  150.       Paul McGinness
  151.